Repository navigation
[v35] Keep the player card off the open leaderboard from 1024px - #6165
Merged
Merged
Conversation
- Even with the clan column hidden (#6147), the centered player card still covered about 65px of the open leaderboard on Poki's 1080p frame (1031×580). - From `lg` (1024px), where the leaderboard opens by default, the leaderboard, the card and the timer sidebar (with the replay panel) now share one top row in `index.html`. It's a 3-column grid, `[minmax(max-content,1fr) | minmax(0,max-content) | minmax(max-content,1fr)]`. When there's room the card stays centered as before. Otherwise it shifts right to clear the leaderboard, and narrows (`lg:max-w-full`) only if it would reach the sidebar. The card's building-count boxes shrink a few pixels rather than wrap. - Below `lg`, nothing changes: each piece keeps its own fixed position (`max-lg:`), as on main. There's no shrinking and no vertical sidebar. - The row is `pointer-events-none`. The leaderboard, the sidebar and the visible card opt back in, so map clicks pass through the empty parts of the row. Headed Chromium against a local dev server, solo game, leaderboard open: | Viewport | Leaderboard | Card | Sidebar | |---|---|---|---| | 1024×600 | 0–331 | 331–797 | 797–1024 | | 1031×580 (Poki on 1080p) | 0–331 | 331–804 | 804–1031 | | 1280×720 | 0–331 | 341–939 (centered) | 1053–1280 | | 1920×1080 | 0–331 | 661–1259 (centered) | 1693–1920 | | 836×470 (below lg) | unchanged from main | | | - Hit tests at 1031×580: empty row space reaches `game-input-overlay`, and the leaderboard and sidebar take clicks. - `npx vitest run`: 9534 passed, 1 skipped. `npm run typecheck`, oxlint and oxfmt are clean. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 9628a3e) Conflicts resolved for v35 by Claude.
Contributor
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cherry-pick of #6157 onto
v35. It conflicted, and Claude resolved it.Conflicted files:
src/client/hud/layers/PlayerInfoOverlay.tsTypecheck, format and lint pass on the result.
Check the fix before merging.